package com.example.flight.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;

import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;

import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;

/**
 * 
 * 
 * @author hws
 * @email 231884142@qq.com
 * @date 2023-06-12
 */
@Data
@TableName("tb_order")
public class OrderEntity implements Serializable {
	private static final long serialVersionUID = 1L;

	/**
	 * 订单id
	 */
	@TableId
	private String oid;
	/**
	 * 用户id
	 */
	private String uid;
	/**
	 * 航班信息id
	 */
	private String fid;
	/**
	 * 舱位
	 */
	private String classType;
	private String identityNumber;
	private String name;
	private BigDecimal price;

	@JsonFormat(locale="zh", timezone="GMT+8", pattern="yyyy-MM-dd HH:mm:ss")
	private Date createTime;
	/**
	 * 航班号
	 */
	@TableField(exist = false)
	private String flightNum;
	/**
	 * 起点
	 */
	@TableField(exist = false)
	private String departure;
	@TableField(exist = false)
	@JsonFormat(locale="zh", timezone="GMT+8", pattern="yyyy-MM-dd HH:mm:ss")
	private Date departureTime;
}
